package com.augurit.common.entity;

import java.util.Date;

import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.SequenceGenerator;
import javax.persistence.Table;

import org.apache.commons.lang.builder.ToStringBuilder;
import org.hibernate.annotations.Cache;
import org.hibernate.annotations.CacheConcurrencyStrategy;

/**
 * 用户Entity类
 * 
 */
@Entity
@Table(name = "OM_USER")
@Cache(usage = CacheConcurrencyStrategy.READ_WRITE)
public class OmUser {

	//属性
	private Long userId;		//主键ID
	private String loginName;	//登录名
	private String password;	//登录密码
	private String userCode;	//用户编号
	private String userName;	//用户姓名
	private String certMode;	//认证模式
	private String cssStyle;	//界面风格
	private Integer sortNo;		//排列顺序
	private String isActive;		//用户状态。0为禁用，1为启用
	private String position;	//在岗情况。在职、离职等
	private String sex;			//性别。男、女
	private String title;		//称谓
	private String officeTel;	//办公电话
	private String mobile;		//手机号码
	private String msn;			//MSN号
	private String email;		//电子邮箱
	private String qq;			//QQ号
	private String rtx;			//RTX号
	private String seatNo;		//座位号
	private Long directorUserId;//直接主管用户ID
	private Date startDate;		//生效日期
	private Date endDate;		//失效日期
	private String creator;		//创建人
	private Date createTime;	//创建时间
	private String updator;		//修改人
	private Date updateTime;	//修改时间
	private String remark;		//备注
	private String publicPassword;//明文密码 

	

	@Id
    @SequenceGenerator(name="SEQ_OM_USER", sequenceName="SEQ_OM_USER", allocationSize=1)
    @GeneratedValue(strategy=GenerationType.SEQUENCE, generator="SEQ_OM_USER")
	public Long getUserId() {
		return userId;
	}

	public void setUserId(Long userId) {
		this.userId = userId;
	}

	public String getLoginName() {
		return loginName;
	}

	public void setLoginName(String loginName) {
		this.loginName = loginName;
	}

	public String getPassword() {
		return password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	public String getUserCode() {
		return userCode;
	}

	public void setUserCode(String userCode) {
		this.userCode = userCode;
	}

	public String getUserName() {
		return userName;
	}

	public void setUserName(String userName) {
		this.userName = userName;
	}

	public String getCertMode() {
		return certMode;
	}

	public void setCertMode(String certMode) {
		this.certMode = certMode;
	}

	public String getCssStyle() {
		return cssStyle;
	}

	public void setCssStyle(String cssStyle) {
		this.cssStyle = cssStyle;
	}

	public Integer getSortNo() {
		return sortNo;
	}

	public void setSortNo(Integer sortNo) {
		this.sortNo = sortNo;
	}

	public String getIsActive() {
		return isActive;
	}

	public void setIsActive(String isActive) {
		this.isActive = isActive;
	}

	public String getPosition() {
		return position;
	}

	public void setPosition(String position) {
		this.position = position;
	}

	public String getSex() {
		return sex;
	}

	public void setSex(String sex) {
		this.sex = sex;
	}

	public String getTitle() {
		return title;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public String getOfficeTel() {
		return officeTel;
	}

	public void setOfficeTel(String officeTel) {
		this.officeTel = officeTel;
	}

	public String getMobile() {
		return mobile;
	}

	public void setMobile(String mobile) {
		this.mobile = mobile;
	}

	public String getMsn() {
		return msn;
	}

	public void setMsn(String msn) {
		this.msn = msn;
	}

	public String getEmail() {
		return email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	public String getQq() {
		return qq;
	}

	public void setQq(String qq) {
		this.qq = qq;
	}

	public String getRtx() {
		return rtx;
	}

	public void setRtx(String rtx) {
		this.rtx = rtx;
	}

	public String getSeatNo() {
		return seatNo;
	}

	public void setSeatNo(String seatNo) {
		this.seatNo = seatNo;
	}

	public Long getDirectorUserId() {
		return directorUserId;
	}

	public void setDirectorUserId(Long directorUserId) {
		this.directorUserId = directorUserId;
	}

	public Date getStartDate() {
		return startDate;
	}

	public void setStartDate(Date startDate) {
		this.startDate = startDate;
	}

	public Date getEndDate() {
		return endDate;
	}

	public void setEndDate(Date endDate) {
		this.endDate = endDate;
	}

	public String getCreator() {
		return creator;
	}

	public void setCreator(String creator) {
		this.creator = creator;
	}

	public Date getCreateTime() {
		return createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	public String getUpdator() {
		return updator;
	}

	public void setUpdator(String updator) {
		this.updator = updator;
	}

	public Date getUpdateTime() {
		return updateTime;
	}

	public void setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
	}

	public String getRemark() {
		return remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}
	

	public String getPublicPassword() {
		return publicPassword;
	}

	public void setPublicPassword(String publicPassword) {
		this.publicPassword = publicPassword;
	}

	@Override
	public String toString() {
		return ToStringBuilder.reflectionToString(this);
	}
}